<template>
	<view class="content" style="width: 100%; height: 100%;">
		<swiper :indicator-dots="true" :autoplay="true" :interval="3000" :duration="1000"
			style="width: 100%; height: 100%;">
			<swiper-item v-for="(item,inndex) in list">
				<view class="swiper-item" style="width: 100%; height: 100%;">
					<image mode="scaleToFill" style="width: 100%; height: 100%;" :src="item.icon"></image>
				</view>
			</swiper-item>
		</swiper>
		<uni-section title="留言列表" sub-title=""  type="line">
			<!-- <uni-list v-for="item,index in canteen" :key="index">
				<uni-list-item :title="item.title" note=""></uni-list-item>
			</uni-list> -->
			<uni-grid :column="5">
				<uni-grid-item v-for="item,index in typelist">
					<view style="display: flex; flex-direction: column; align-items: center; ">
						<image :src="'../../static/'+item.icon" style="width: 80rpx; height: 80rpx; " mode=""></image>
						<view>{{item.typename}}</view>
					</view>
				</uni-grid-item>
			</uni-grid>
		</uni-section>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				canteen: [{
						title: '食堂1'
					},
					{
						title: '食堂2'
					},
					{
						title: '食堂3'
					}
				],
				list: [{
						icon: '../../static/images/01.jpg'
					},
					{
						icon: '../../static/images/02.jpg'
					},
					{
						icon: '../../static/images/03.jpg'
					},
					{
						icon: '../../static/images/04.jpg'
					}
				],
				typelist: [{
						"id": 1,
						"typename": "新闻",
						"icon": "/class/news.png"
					},
					{
						"id": 2,
						"typename": "公告",
						"icon": "/class/announcement.png"
					},
					{
						"id": 3,
						"typename": "同学",
						"icon": "/class/classmate.png"
					},
					{
						"id": 4,
						"typename": "电话",
						"icon": "/class/telephone.png"
					},
					{
						"id": 5,
						"typename": "留言",
						"icon": "/class/leaveword.png"
					}
					// {
					// 	"id": 6,
					// 	"typename": "酒水",
					// 	"icon": "/images/drink.png"
					// },
					// {
					// 	"id": 7,
					// 	"typename": "火锅",
					// 	"icon": "/images/hotpot.png"
					// },

					// {
					// 	"id": 8,
					// 	"typename": "更多",
					// 	"icon": "/images/more2.png"
					// }
				]
			}
		},
		onLoad() {

		},
		methods: {

		}
	}
</script>

<style>
	page {
		width: 100%;
		height: 400rpx;
	}
</style>